import request from '@/utils/request'

export function loadChannelPackage() {
  return request({
    url: '/system/channelPackage/load',
    method: 'get'
  })
}


// 查询渠道包列表
export function listChannelPackage(query) {
  return request({
    url: '/system/channelPackage/list',
    method: 'get',
    params: query
  })
}

// 查询渠道包详细
export function getChannelPackage(id) {
  return request({
    url: '/system/channelPackage/' + id,
    method: 'get'
  })
}

// 新增渠道包
export function addChannelPackage(data) {
  return request({
    url: '/system/channelPackage',
    method: 'post',
    data: data
  })
}

// 修改渠道包
export function updateChannelPackage(data) {
  return request({
    url: '/system/channelPackage',
    method: 'put',
    data: data
  })
}

// 删除渠道包
export function delChannelPackage(id) {
  return request({
    url: '/system/channelPackage/' + id,
    method: 'delete'
  })
}

// 导出渠道包
export function exportChannelPackage(query) {
  return request({
    url: '/system/channelPackage/export',
    method: 'get',
    params: query
  })
}